package com.linh.trade;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import static com.linh.trade.Constants.AMOUNT_FORMAT;

public class TraderActionLog implements TraderActionListener {

	private static final Logger LOG = LoggerFactory
			.getLogger(TraderActionLog.class);

	
	public void onGoingLong(Trade trade, double budget) {
		LOG.info(trade.getOpenLine() + " (" + AMOUNT_FORMAT.format(budget)
				+ ")");

	}

	
	public void onGoingShort(Trade trade, double budget) {
		LOG.info(trade.getOpenLine() + " (" + AMOUNT_FORMAT.format(budget)
				+ ")");

	}

	
	public void onPositionClosed(Trade trade, double budget) {
		LOG.info(trade.getCloseLine() + " (" + AMOUNT_FORMAT.format(budget)
				+ ")");
	}

}
